<!DOCTYPE HTML>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<meta charset="utf-8">
<head th:include="include :: header"></head>
<body class="gray-bg">
<div class="container-div">
    <div class="btn-group-sm hidden-xs" id="toolbar" role="group">

    </div>

    <div class="col-sm-12 select-table table-striped">
        <table id="bootstrap-table" data-mobile-responsive="true"></table>
    </div>
</div>
<div th:include="include :: footer"></div>
<script th:inline="javascript">
    var editFlag = [[${@permission.hasPermi('module:redWelfareBagUser:edit')}]];
    var removeFlag = [[${@permission.hasPermi('module:redWelfareBagUser:remove')}]];
    var prefix = ctx + "module/redWelfareBagUser";

    $(function () {
        var options = {
            url: prefix + "/list",
            createUrl: prefix + "/add",
            updateUrl: prefix + "/edit/{id}",
            removeUrl: prefix + "/remove",
            modalName: "福利包的接收用户",
            queryParams: queryParams,
            columns: [{
                checkbox: true
            },
                {
                    field: 'bagUserId',
                    title: '接收ID'
                },
                {
                    field: 'bagId',
                    title: '福利包ID'
                },
                {
                    field: 'userId',
                    title: '用户ID'
                },
                {
                    field: 'bagMoney',
                    title: '抢到金额'
                },
                {
                    field: 'status',
                    title: '状态 0.已分配 1.已入账'
                },
                {
                    field: 'bagTime',
                    title: '抢包时间'
                },
                {
                    field: 'createTime',
                    title: '创建时间'
                }]
        };
        $.table.init(options);
    });

    function queryParams(params) {
        return {
            redWelfareBagId: $("#redWelfareBagId").val(),
            pageSize: params.limit,
            pageNum: params.offset / params.limit + 1,
            searchValue: params.search,
            orderByColumn: params.sort,
            isAsc: params.order
        };
    }

</script>
</body>
</html>